package cn.tedu.submarine_1;

import javax.swing.*;

public class Mine extends SeaObject{
    public Mine(int x, int y) {
        super(11,11,x,y,1);
    }

    @Override
    public ImageIcon getImage() {
        return Images.mine;
    }
    public void move(){
        setY(getY()-getSpeed());
    }
    //判断是否越界
    public boolean isOutOfBounds(){
        return this.getY()<=150-this.getHeight();
    }
}
